<template>
	<view class="content">
		<u-icon name="photo" @click="openPop"></u-icon>
		{{$userInfo()}}
		<br/>
		name: {{title}}
		<br/>
		name: {{$userInfo().name}}
		<br/>
		分包测试<br/>
		<u-button size="mini" rippler rippler-bg-color="rgba(0,0,0,1)" type="primary" @click="toOne">到客户模块</u-button>
		<u-button size="mini" rippler rippler-bg-color="rgba(0,0,0,1)" type="primary" @click="toOne2">到客户消息</u-button>
		<u-button size="mini" rippler rippler-bg-color="rgba(0,0,0,1)" type="primary" @click="toTwo">到商品模块</u-button>
		<u-button size="mini" rippler rippler-bg-color="rgba(0,0,0,1)" type="primary" @click="toThree">到订单模块</u-button>
		<br/>
		自定义组件<br/>
		<myView background="red" height="100"></myView>

	</view>
</template>

<script>
	export default {
		data() {
			return {
				title: 'Hello'
			}
		},
		created() {
			this.$setUserInfo({name:'hello uniapp',age:19});
			this.$u.api.test1();
			this.$log.debug("debug","content")
			this.$log.info("info","content")
			this.title=this.$store.state.userInfo.name
		},
		onLoad() {
			
		},
		methods: {
			openPop(){
				this.$pop('tip','content')
			},
			toOne(){
				this.$u.route({
					url: "subpages/customer/index"
				})
			},
			toOne2(){
				this.$u.route({
					url: "subpages/customer/message/message"
				})
			},
			toTwo(){
				this.$u.route({
					url: "subpages/goods/index"
				})
			},
			toThree(){
				this.$u.route({
					url: "subpages/order/index"
				})
			}

		}
	}
</script>

<style>
	
</style>
